package com.ruoyi.web.service;

import com.ruoyi.web.domain.FileExportVo;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * 文件存储
 *
 * @author szq
 * @date 2022-07-12
 */
public interface MongoFileService {
	/**
	 * 文件上传
	 *
	 * @param file
	 * @param type
	 * @return
	 */
	FileExportVo uploadFile(MultipartFile file, Integer type, HttpServletRequest request) throws Exception;

	/**
	 * 多文件上传
	 * @param files
	 * @return
	 */
	List<FileExportVo> uploadFiles(List<MultipartFile> files, Integer type,HttpServletRequest request);

	/**
	 * 文件下载
	 * @param fileId
	 * @return
	 */
	FileExportVo downloadFile(Long fileId);

	/**
	 * 文件删除
	 * @param fileId
	 */
	void removeFile(Long fileId);


}
